package cn.weakup.skiplist;

/**
 * <p>
 *      跳表节点元素
 * </p>
 *
 * @Author: Liziba
 * @Date: 2021/7/5 21:01
 */
public class Node {

    /** 节点的分数值，根据分数值来排序 */
    public Double score;
    /** 节点存储的真实数据 */
    public String value;
    /** 当前节点的 前、后、下、上节点的引用 */
    public Node prev, next, down, up;

    public Node(Double score) {
        this.score = score;
        prev = next = down = up = null;
    }

    public Node(Double score, String value) {
        this.score = score;
        this.value = value;
    }
}
